home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-04 / gs24src.zip / MAN1.DOC < prev    next >
Text File  |  1992-03-18  |  16KB  |  568 lines

  1. 
  2. From kankkune  Fri Dec 20 11:17:53 1991 remote from cs.Helsinki.FI
  3. Received: by aladdin.com (UUL1.3#5127)
  4.     from decwrl with UUCP; Fri, 20 Dec 91 11:18:24 PDT
  5. Received: by uucp-gw-1.pa.dec.com; id AA23754; Fri, 20 Dec 91 11:17:53 -0800
  6. Received: from poros (poros.Helsinki.FI) by hydra.Helsinki.FI (4.1/SMI-4.1/36)
  7.     id AA04379; Fri, 20 Dec 91 21:17:42 +0200
  8. Date: Fri, 20 Dec 91 21:17:42 +0200
  9. From: kankkune@cs.Helsinki.FI (Risto Kankkunen)
  10. Message-Id: <9112201917.AA04379@hydra.Helsinki.FI>
  11. X-Mailer: Mail User's Shell (7.2.0 10/31/90)
  12. To: ghost@aladdin.com
  13. Subject: Here is a unix manual page for gs 2.3
  14.  
  15. I was installing gs version 2.3 when I noticed, that there was only the
  16. very minimal manual page for it. So, I wound up hacking one from the
  17. file use.doc by reorganizing, adding formatting and some bits and pieces
  18. of my own. I thought you might find use to it, so I'm sending it here to
  19. you. Below is the troff source and after that is a pre-fomatted version,
  20. in case you don't have access to troff and want to see what the file
  21. looks like. The files are separated with cut lines and total about 14K,
  22. so I think this should get to you without truncation.
  23.  
  24. - cut here --- cut here --- cut here --- cut here --- cut here --- cut here -
  25. .TH GS 1 "20 December 1991"
  26. .SH NAME
  27. gs \- ghostscript previewer, version 2.3.
  28. .SH SYNOPSIS
  29. .B gs
  30. [
  31. .B \-D
  32. .Iname
  33. .B \-S
  34. .I name
  35. .B \-q
  36. .B \-g
  37. .I number1
  38. x
  39. .I number2
  40. .B \-I
  41. .I directories
  42. .B \-h \- \-\-
  43. .I prog args...
  44. ]
  45. [
  46. .I file
  47. ]...
  48.  
  49. .SH DESCRIPTION
  50. Ghostscript is a programming language similar to Adobe Systems'
  51. PostScript (tm) language, which is in turn similar to Forth.
  52. .B Gs
  53. reads
  54. .I file
  55. and displays or prints it as a Ghostscript file to an output device.
  56.  
  57. To invoke the interpreter, give the command
  58. .B gs
  59. .I filename1 ... filenameN.
  60. The interpreter will read in the files in sequence and execute them.
  61. After doing this, it reads further input from the primary input stream
  62. (normally the keyboard). Each line (i.e. characters up to a
  63. .B <return>
  64. ) is interpreted separately. To exit from the interpreter, type
  65. .B quit<return>.
  66. The interpreter also exits gracefully if it encounters end-of-file.
  67. Typing the interrupt character, e.g.,
  68. .B control-C,
  69. is also safe.
  70.  
  71. .SH OPTIONS
  72. The interpreter recognizes several options described below, which may
  73. appear anywhere in the command line and apply to all files thereafter.
  74. .TP
  75. .B \-\-
  76. .I filename arg1 ...
  77. Takes the next argument as a file name as usual, but takes all remaining
  78. arguments (even if they have the syntactic form of switches) and defines
  79. the name
  80. .B ARGUMENTS
  81. in
  82. .B userdict
  83. (not
  84. .B systemdict
  85. ) as an array of those strings,
  86. .I before
  87. running the file. When
  88. .B gs
  89. finishes executing the file, it exits back to the shell.
  90. .TP
  91. .B \-Dname\=token
  92. .TP
  93. .B \-dname\=token
  94. Define a name in
  95. .B systemdict
  96. with the given definition. The token must be exactly one token (as
  97. defined by the
  98. .B token
  99. operator) and must not contain any whitespace.
  100. .TP
  101. .B \-Dname
  102. .TP
  103. .B \-dname
  104. Define a name in
  105. .B systemdict
  106. with value null.
  107. .TP
  108. .B \-Sname=string
  109. .TP
  110. .B \-sname=string
  111. Define a name in
  112. .B systemdict
  113. with a given string as value. This is different from
  114. .B \-D.
  115. For example,
  116. .B \-Dname=35
  117. is equivalent to the program fragment
  118. .B /name 35 def
  119. whereas
  120. .B \-Sname=35
  121. is equivalent to
  122. .B /name (35) def.
  123.  
  124. Note that
  125. .B gs_init.ps
  126. makes
  127. .B systemdict
  128. read-only, so the values of names defined with
  129. .B \-D
  130. or
  131. .B \-S
  132. cannot be changed (although, of course, they can be superseded by
  133. definitions in
  134. .B userdict
  135. or other dictionaries).
  136.  
  137. Ghostscript may be built with multiple output devices (you can see the
  138. list of supported devices by giving the command
  139. .B gs \-h
  140. ). Ghostscript normally opens the first one and directs output to it.
  141. To use device
  142. .I xyz
  143. as the initial output device, include the option
  144. .B \-sDEVICE\=
  145. .I xyz
  146. in the command line.  Note that this switch must precede the first .ps
  147. file, and only its first invocation has any effect.
  148.  
  149. Including
  150. .B \-dNODISPLAY
  151. in the command line will suppress the normal initialization of the
  152. output device. This may be useful when debugging. Similarly,
  153. .B \-dNOCACHE
  154. disables character caching, and
  155. .B \-dNOBIND
  156. disables the 'bind' operator.
  157. .B \-dNOPAUSE
  158. disables the prompt and pause at the end of each page; this may be
  159. desirable for applications where another program is 'driving'
  160. .B gs.
  161. .TP
  162. .B \-q
  163. Quiet startup \- suppress normal startup messages, and also do the
  164. equivalent of
  165. .B \-dQUIET.
  166. .TP
  167. .B \-g
  168. .I number1
  169. x
  170. .I number2
  171. Equivalent to
  172. .B \-dDEVICEWIDTH\=
  173. .I number1
  174. and
  175. .B \-dDEVICEHEIGHT\=
  176. .I number2.
  177. This is for the benefit of devices (such as display windows) that
  178. require (or allow) width and height to be specified.
  179. .TP
  180. .B \-I
  181. .Idirectories
  182. Adds the designated list of
  183. .I directories
  184. at the head of the search path for library files. This path is used to
  185. locate the initialization and font files, and also files given to the
  186. .B run
  187. operator.
  188. .B gs
  189. searches these files using the specified
  190. .B \-I
  191. options, the contents of the environment variable
  192. .B GS_LIB
  193. and some site specific default values.
  194.  
  195. To work properly
  196. .B gs
  197. needs to have access to the initialization files
  198. .B
  199. gs_init.ps, gs_statd.ps, gs_fonts.ps
  200. and various font files (these usually have extension .gsf or .pfa). The
  201. program is usually configured so that it finds these files
  202. automatically. You can use the
  203. .B \-I
  204. option if you want to add your own fonts or override the system
  205. initialization files.
  206. .TP
  207. .B \-h
  208. Prints a short usage message listing the available command line options
  209. and supported output devices.
  210. .TP
  211. .B \-
  212. This is not really a switch.  It indicates to
  213. .B gs
  214. that the standard input is coming from a file or a pipe.
  215. .B gs
  216. reads from stdin until reaching end-of-file, executing it like any other
  217. file, and then continues processing the command line.  At the end of the
  218. command line,
  219. .B gs
  220. exits rather than going into its interactive mode.
  221. .SH X WINDOW SYSTEM RESOURCES
  222. .B gs
  223. looks for the following resources under the program name
  224. .B Ghostscript:
  225. .TP
  226. .B borderWidth
  227. the border width in pixels (default = 1)
  228. .TP
  229. .B borderColor
  230. the name of the border color (default = black)
  231. .TP
  232. .B geometry
  233. the window size and placement, WxH+X+Y
  234. .TP
  235. .B xResolution
  236. the number of x pixels per inch (default is computed from
  237. .B WidthOfScreen
  238. and
  239. .B WidthMMOfScreen
  240. )
  241. .TP
  242. .B yResolution
  243. the number of y pixels per inch (default is computed from
  244. .B HeightOfScreen
  245. and
  246. .B HeightMMOfScreen
  247. )
  248. .SH EXAMPLES
  249. To change output to printer in a normal configuration that includes an
  250. PaintJet printer driver, you might use the shell command
  251. .B gs \-sDEVICE\=paintjet myfile.ps
  252. instead of just
  253. .B gs myfile.ps
  254. Alternatively, you can type
  255.  
  256. .B (paintjet) selectdevice
  257.  
  258. .B (myfile.ps) run.
  259.  
  260. All output then goes to the printer instead of the display until further
  261. notice.  You can switch devices at any time by using the selectdevice
  262. procedure, e.g.,
  263. .B (x11) selectdevice
  264. or
  265. .B (paintjet) selectdevice
  266.  
  267. To find out what devices are available, just type
  268. .B devicenames.
  269. .SH FILES
  270. .TP
  271. .B gs_fonts.ps
  272. Font initialization.
  273. .TP
  274. .B gs_init.ps
  275. Various initialization routines.
  276. .TP
  277. .B gs_statd.ps
  278. Dummy
  279. .B statusdict
  280. definitions for the benefit of PostScript files that think they are
  281. being printed on a hardcopy printer.
  282. .TP
  283. .B Fontmap
  284. A catalog of fonts known to
  285. .B gs.
  286. Lists the GhostScript name, corresponding font file name, font encoding
  287. and font identification number for each font that
  288. .B gs
  289. knows.
  290. .SH "SEE ALSO"
  291. dvi2ps(1), lpr(1)
  292. .SH BUGS
  293. Beta Software.
  294. See the netnews group ``gnu.ghostscript.bugs''.
  295. - cut here --- cut here --- cut here --- cut here --- cut here --- cut here -
  296.  
  297.  
  298.  
  299. GS(1)                    USER COMMANDS                      GS(1)
  300.  
  301.  
  302.  
  303. NAME
  304.      gs - ghostscript previewer, version 2.3.
  305.  
  306. SYNOPSIS
  307.      gs [ -D -S _n_a_m_e -q -g _n_u_m_b_e_r_1 x _n_u_m_b_e_r_2 -I _d_i_r_e_c_t_o_r_i_e_s -h  -
  308.      -- _p_r_o_g _a_r_g_s... ] [ _f_i_l_e ]...
  309.  
  310.  
  311. DESCRIPTION
  312.      Ghostscript is a programming language similar to Adobe  Sys-
  313.      tems'  PostScript (tm) language, which is in turn similar to
  314.      Forth.  Gs reads  _f_i_l_e  and  displays  or  prints  it  as  a
  315.      Ghostscript file to an output device.
  316.  
  317.      To invoke the interpreter, give the command gs _f_i_l_e_n_a_m_e_1 ...
  318.      _f_i_l_e_n_a_m_e_N.  The  interpreter  will  read  in  the  files  in
  319.      sequence and execute  them.   After  doing  this,  it  reads
  320.      further  input  from  the primary input stream (normally the
  321.      keyboard). Each line (i.e. characters up to a <return> )  is
  322.      interpreted  separately.  To exit from the interpreter, type
  323.      quit<return>. The interpreter also exits  gracefully  if  it
  324.      encounters  end-of-file.   Typing  the  interrupt character,
  325.      e.g., control-C, is also safe.
  326.  
  327.  
  328. OPTIONS
  329.      The interpreter recognizes several options described  below,
  330.      which  may  appear anywhere in the command line and apply to
  331.      all files thereafter.
  332.  
  333.      --   _f_i_l_e_n_a_m_e _a_r_g_1 ... Takes the next  argument  as  a  file
  334.           name  as usual, but takes all remaining arguments (even
  335.           if they  have  the  syntactic  form  of  switches)  and
  336.           defines  the name ARGUMENTS in userdict (not systemdict
  337.           ) as an array of  those  strings,  _b_e_f_o_r_e  running  the
  338.           file.  When  gs  finishes  executing the file, it exits
  339.           back to the shell.
  340.  
  341.      -Dname=token
  342.  
  343.      -dname=token
  344.           Define a name in systemdict with the given  definition.
  345.           The  token must be exactly one token (as defined by the
  346.           token operator) and must not contain any whitespace.
  347.  
  348.      -Dname
  349.  
  350.      -dname
  351.           Define a name in systemdict with value null.
  352.  
  353.      -Sname=string
  354.  
  355.  
  356.  
  357.  
  358. Sun Release 4.1   Last change: 20 December 1991                 1
  359.  
  360.  
  361.  
  362.  
  363.  
  364.  
  365. GS(1)                    USER COMMANDS                      GS(1)
  366.  
  367.  
  368.  
  369.      -sname=string
  370.           Define a name in systemdict  with  a  given  string  as
  371.           value.   This   is  different  from  -D.  For  example,
  372.           -Dname=35 is equivalent to the program  fragment  /name
  373.           35  def  whereas  -Sname=35 is equivalent to /name (35)
  374.           def.
  375.  
  376.           Note that gs_init.ps makes systemdict read-only, so the
  377.           values of names defined with -D or -S cannot be changed
  378.           (although, of course, they can be superseded by defini-
  379.           tions in userdict or other dictionaries).
  380.  
  381.           Ghostscript may be built with multiple  output  devices
  382.           (you  can  see  the list of supported devices by giving
  383.           the command gs -h ).  Ghostscript  normally  opens  the
  384.           first  one and directs output to it.  To use device _x_y_z
  385.           as the initial output device, include the option -sDEV-
  386.           ICE=  _x_y_z  in  the command line.  Note that this switch
  387.           must precede the first .ps file,  and  only  its  first
  388.           invocation has any effect.
  389.  
  390.           Including -dNODISPLAY in the command line will suppress
  391.           the  normal  initialization  of the output device. This
  392.           may be useful when debugging. Similarly, -dNOCACHE dis-
  393.           ables  character  caching,  and  -dNOBIND  disables the
  394.           'bind' operator.  -dNOPAUSE  disables  the  prompt  and
  395.           pause  at  the  end of each page; this may be desirable
  396.           for applications where another program is 'driving' gs.
  397.  
  398.      -q   Quiet startup - suppress normal startup  messages,  and
  399.           also do the equivalent of -dQUIET.
  400.  
  401.      -g   _n_u_m_b_e_r_1 x _n_u_m_b_e_r_2 Equivalent to -dDEVICEWIDTH=  _n_u_m_b_e_r_1
  402.           and -dDEVICEHEIGHT= _n_u_m_b_e_r_2. This is for the benefit of
  403.           devices (such as  display  windows)  that  require  (or
  404.           allow) width and height to be specified.
  405.  
  406.      -I   Adds the designated list of _d_i_r_e_c_t_o_r_i_e_s at the head  of
  407.           the search path for library files. This path is used to
  408.           locate the initialization  and  font  files,  and  also
  409.           files  given  to  the  run operator.  gs searches these
  410.           files using the specified -I options, the  contents  of
  411.           the  environment variable GS_LIB and some site specific
  412.           default values.
  413.  
  414.           To work properly gs needs to have access  to  the  ini-
  415.           tialization  files gs_init.ps, gs_statd.ps, gs_fonts.ps
  416.           and various font files (these  usually  have  extension
  417.           .gsf  or  .pfa).  The  program is usually configured so
  418.           that it finds these files automatically.  You  can  use
  419.           the  -I  option  if  you  want to add your own fonts or
  420.           override the system initialization files.
  421.  
  422.  
  423.  
  424. Sun Release 4.1   Last change: 20 December 1991                 2
  425.  
  426.  
  427.  
  428.  
  429.  
  430.  
  431. GS(1)                    USER COMMANDS                      GS(1)
  432.  
  433.  
  434.  
  435.      -h   Prints a short usage message listing the available com-
  436.           mand line options and supported output devices.
  437.  
  438.      -    This is not really a switch.  It indicates to  gs  that
  439.           the standard input is coming from a file or a pipe.  gs
  440.           reads from stdin until reaching end-of-file,  executing
  441.           it  like  any other file, and then continues processing
  442.           the command line.  At the end of the command  line,  gs
  443.           exits rather than going into its interactive mode.
  444.  
  445. X WINDOW SYSTEM RESOURCES
  446.      gs looks for the following resources under the program  name
  447.      Ghostscript:
  448.  
  449.      borderWidth
  450.           the border width in pixels (default = 1)
  451.  
  452.      borderColor
  453.           the name of the border color (default = black)
  454.  
  455.      geometry
  456.           the window size and placement, WxH+X+Y
  457.  
  458.      xResolution
  459.           the number of x pixels per inch  (default  is  computed
  460.           from WidthOfScreen and WidthMMOfScreen )
  461.  
  462.      yResolution
  463.           the number of y pixels per inch  (default  is  computed
  464.           from HeightOfScreen and HeightMMOfScreen )
  465.  
  466. EXAMPLES
  467.      To change output to printer in a normal  configuration  that
  468.      includes an PaintJet printer driver, you might use the shell
  469.      command gs -sDEVICE=paintjet myfile.ps instead  of  just  gs
  470.      myfile.ps Alternatively, you can type
  471.  
  472.      (paintjet) selectdevice
  473.  
  474.      (myfile.ps) run.
  475.  
  476.      All output then goes to the printer instead of  the  display
  477.      until further notice.  You can switch devices at any time by
  478.      using the selectdevice procedure, e.g.,  (x11)  selectdevice
  479.      or (paintjet) selectdevice
  480.  
  481.      To find out what devices  are  available,  just  type  devi-
  482.      cenames.
  483.  
  484. FILES
  485.      gs_fonts.ps
  486.           Font initialization.
  487.  
  488.  
  489.  
  490. Sun Release 4.1   Last change: 20 December 1991                 3
  491.  
  492.  
  493.  
  494.  
  495.  
  496.  
  497. GS(1)                    USER COMMANDS                      GS(1)
  498.  
  499.  
  500.  
  501.      gs_init.ps
  502.           Various initialization routines.
  503.  
  504.      gs_statd.ps
  505.           Dummy  statusdict  definitions  for  the   benefit   of
  506.           PostScript files that think they are being printed on a
  507.           hardcopy printer.
  508.  
  509.      Fontmap
  510.           A catalog of fonts known to gs. Lists  the  GhostScript
  511.           name,  corresponding  font file name, font encoding and
  512.           font identification number for each font that gs knows.
  513.  
  514. SEE ALSO
  515.      dvi2ps(1), lpr(1)
  516.  
  517. BUGS
  518.      Beta     Software.      See      the      netnews      group
  519.      ``gnu.ghostscript.bugs''.
  520.  
  521.  
  522.  
  523.  
  524.  
  525.  
  526.  
  527.  
  528.  
  529.  
  530.  
  531.  
  532.  
  533.  
  534.  
  535.  
  536.  
  537.  
  538.  
  539.  
  540.  
  541.  
  542.  
  543.  
  544.  
  545.  
  546.  
  547.  
  548.  
  549.  
  550.  
  551.  
  552.  
  553.  
  554.  
  555.  
  556. Sun Release 4.1   Last change: 20 December 1991                 4
  557.  
  558.  
  559.  
  560. - cut here --- cut here --- cut here --- cut here --- cut here --- cut here -
  561.  
  562.  
  563. -- 
  564.  Risto Kankkunen                   kankkune@cs.Helsinki.FI (Internet)
  565.  Department of Computer Science    kankkunen@finuh          (Bitnet)
  566.  University of Helsinki, Finland   ..!mcsun!uhecs!kankkune   (UUCP)
  567. 
  568.